from BruTile.Cache.MemoryCache import MemoryCache
from UI.Fetcher.TileFetcher import TileFetcher

class TileLayer(object):
    
    tile_schema = None
    tile_fetcher = None
    memory_cache = MemoryCache()

    def __init__(self, tile_schema, method_data_changed):
        self.tile_schema = tile_schema
        self.tile_fetcher = TileFetcher()
        self.tile_fetcher.InitMainThread(self.memory_cache, method_data_changed, self.tile_schema, self.tile_schema.url)